From: Ivan Diaz Date: Thu, 16 Oct 2025 01:51:01 +0000 (-0500) Subject: luci-app-watchcat: use DynamicList for pinghosts X-Git-Url: http://git.openwrt.org/%22http:/oss.oetiker.ch/rrdtool//%22/%22http:/oss.oetiker.ch/rrdtool/%22?a=commitdiff_plain;h=4c4b5c31bd529b9d713cd6c9a167dc578c5b8e77;p=project%2Fluci.git luci-app-watchcat: use DynamicList for pinghosts Switch to DynamicList to improve multi-host handling in the UI. Signed-off-by: Ivan Diaz --- diff --git a/applications/luci-app-watchcat/htdocs/luci-static/resources/view/watchcat.js b/applications/luci-app-watchcat/htdocs/luci-static/resources/view/watchcat.js index ed9318d485..96c2fc2d9c 100644 --- a/applications/luci-app-watchcat/htdocs/luci-static/resources/view/watchcat.js +++ b/applications/luci-app-watchcat/htdocs/luci-static/resources/view/watchcat.js @@ -56,16 +56,6 @@ return view.extend({ o.depends({ mode: "restart_iface" }); o.depends({ mode: "run_script" }); - o.load = function(section_id) { - return (String(this.map.data.get('watchcat', section_id, 'pinghosts') || '') - .trim().split(/\s+/).filter(Boolean)) - } - - o.write = function(section_id, formvalue) { - this.map.data.set('watchcat', section_id, 'pinghosts', - (formvalue || []).map(v => String(v).trim()).filter(Boolean).join(' ')) - } - o = s.taboption('general', form.ListValue, 'addressfamily', _('Address family for pinging the host')); o.default = 'any';